<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="./lib/react.development.js"></script>
    <script src="./lib/react-dom.development.js"></script>
    <script src="./lib/babel.min.js"></script>
</head>
<body>
    <div id="root"></div>
</body>
<script type="text/babel">
    /**
     * 唯一的根节点
     * 
     */
    const root = ReactDOM.createRoot(document.querySelector("#root"));
    const {Fragment} = React;
    console.log(React.Fragment);
    root.render((
        /*写法一*/
        <Fragment>
            <h3>我是标题</h3>
            <p>我是内容</p>
        </Fragment>
    ))

    root.render((
        /*写法二*/
        <React.Fragment>
            <h3>我是标题</h3>
            <p>我是内容</p>
        </React.Fragment>
    ))

    root.render((
        /*写法三 [推荐]*/
        <>
            <h3>我是标题</h3>
            <p>我是内容</p>
        </>
    ))
</script>
</html>